Forward slicing of functional logic programs by partial evaluation

نویسندگان

  • Josep Silva
  • Germán Vidal
چکیده

Program slicing has been mainly studied in the context of imperative languages, where it has been applied to a wide variety of software engineering tasks, like program understanding, maintenance, debugging, testing, code reuse, etc. This work introduces the first forward slicing technique for declarative multi-paradigm programs which integrate features from functional and logic programming. Basically, given a program and a slicing criterion (a function call in our setting), the computed forward slice contains those parts of the original program which are reachable from the slicing criterion. Our approach to program slicing is based on an extension of (online) partial evaluation. Therefore, it provides a simple way to develop program slicing tools from existing partial evaluators and helps to clarify the relation between both methodologies. A slicing tool for the multi-paradigm language Curry, which demonstrates the usefulness of our approach, has been implemented in Curry itself.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

A Lightweight Approach to Program Specialization⋆

Within the imperative programming paradigm, program slicing has been widely used as a basis to solve many software engineering problems, like debugging, testing, differencing, specialization, and merging. In this work, we present a lightweight approach to program specialization of lazy functional logic programs which is based on dynamic slicing. The kind of specialization performed by our appro...

متن کامل

Forward Slicing of Multi-paradigm Declarative Programs Based on Partial Evaluation

Program slicing has been mainly studied in the context of imperative languages, where it has been applied to many software engineering tasks, like program understanding, maintenance, debugging, testing, code reuse, etc. This paper introduces the first forward slicing technique for multi-paradigm declarative programs. In particular, we show how program slicing can be defined in terms of online p...

متن کامل

Forward Slicing by Conjunctive Partial Deduction and Argument Filtering

Program slicing is a well-known methodology that aims at identifying the program statements that (potentially) affect the values computed at some point of interest. Within imperative programming, this technique has been successfully applied to debugging, specialization, reuse, maintenance, etc. Due to its declarative nature, adapting the slicing notions and techniques to a logic programming set...

متن کامل

Program Specialization via Program Slicing

This paper concerns the use of program slicing to perform a certain kind of program-specialization operation. We show that the specialization operation that slicing performs is different from the specialization operations performed by algorithms for partial evaluation, supercompilation, bifurcation, and deforestation. To study the relationship between slicing and these operations in a simplifie...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:
  • TPLP

دوره 7  شماره 

صفحات  -

تاریخ انتشار 2007